<?php
class indexController extends accessController{
    public function index(){
        
    }
	public function table_cache(){
		$dir=APPPATH.'runtime/table_cache/';
//		$files=scandir($dir);
//		foreach($files as $file){
//			if(in_array($file,array('.','..','index.html'))) continue;
//			unlink($dir.$file);
//		}
		$dh   =  opendir ( $dir );
		while ( false  !== ( $filename  =  readdir ( $dh ))) {
			 $files [] =  $filename ;
		}
		closedir($dh);
		foreach($files as $file){
			if(in_array($file,array('.','..','index.html'))) continue;
			unlink($dir.$file);
		}

		msg(1);
	}
}

